﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace prjYan.Forum.Controllers
{
    public class PartialController : Controller
    {
        //
        // GET: /Partial/

        //By Tuan
        [ChildActionOnly]
        public PartialViewResult Pagging(string linktext, int pageSize, int pageIndex, int totalCount)
        {
            ViewBag.LinkText = linktext;
            ViewBag.PageIndex = pageIndex;
            ViewBag.NumPage = totalCount % pageSize > 0 ? totalCount / pageSize + 1 : totalCount / pageSize;

            return PartialView();
        }

    }
}
